<include file="Public:header" />
<div id="zoneHeader">
    <h2>站长结算明细数据</h2>
</div><!--/#zoneHeader-->
<div id="zoneBody">
    <div id="zoneBodySearch">
        <form id="formSearch" action="?c={$Think.const.CONTROLLER_NAME}">
            <input type="hidden" name="sort" />
            <input type="hidden" name="sortdir" />

            <ul>
                <li><b>日期：</b><input type="text" name="day" class="fW100p"  t="datebox"></li>
                <li><select name="ad_type">
                        <option value="">广告类型</option>
                        <volist name=":C('AD_TYPE')" id="vo">
                        <option value="{$key}">{$vo}</option>
                        </volist>
                    </select>
                </li>
                <li><b>站长编号：</b><input type="text" name="uid" class="fW80p" /></li>
                <li rel="searchMoreItem"><b>广告位编号：</b><input type="text" name="zone_id" class="fW80p" /></li>
                <li rel="searchMoreItem"><b>网站编号：</b><input type="text" name="site_id" class="fW80p" /></li>
                <li rel="searchMoreItem"><b>IP：</b><input type="text" name="ip" class="fW100p" /></li>
                <li>
                    <b>所属计划：</b>
                    <select name="plan_id">
                        <option value="">选择计划</option>
                        <volist name=":getPlanNameByDay($_GET['day'])" id="vo">
                        <option value="{$vo.plan_id}">#{$vo.plan_id}  {$vo.plan_name}</option>
                        </volist>
                    </select>
                </li>
                <li rel="searchMoreItem"><b>广告编号：</b><input type="text" name="ad_id" class="fW80p" /></li>
                <li><button type="button" id="as" class="btnSearch">查询</button></li>
                <li><label><input type="checkbox" class="btnSearchMore" /><span>高级查询</span></label></li>
            </ul>
        </form>
    </div><!--/#zoneBodySearch-->
    <div id="zoneBodyContent">
        <table class="table2">
            <thead>
                <tr>
                    <th><a href="javascript:;" sort="ad_type">类型</a></th>
                    <th>站长</th>
                    <th><a href="javascript:;" sort="zone_id">广告位</a></th>
                    <th><a href="javascript:;" sort="site_id">网站</a></th>
                    <th><a href="javascript:;" sort="plan_id">计划ID</a></th>
                    <th><a href="javascript:;" sort="ad_id">广告ID</a></th>
                    <th><a href="javascript:;" sort="ip">IP</a></th>
                    <th><a href="javascript:;" sort="resolution">分辨率</a></th>
                    <th>运营商</th>
                    <th>联网方式</th>
                    <th>系统</th>
                    <th>手机品牌</th>
                    <th><a href="javascript:;" sort="status">有效</a></th>
                </tr>
            </thead>
            <tbody>
                <volist  name="page.record" id="vo">
                <tr>
                    <td>{$vo.ad_type|getAdTypeCn}</td>
                    <td><a href="?c=Siter&uid={$vo.uid}" target="_blank">{$vo.uid}</a></td>
                    <td><a href="?c=Zone&search_item_1=zone_id&search_item_val_1={$vo.zone_id}&zone_id={$vo.zone_id}" target="_blank">{$vo.zone_id}</a></td>
                    <td><a href="?c=Site&search_item_1=site_id&search_item_val_1={$vo.site_id}&site_id={$vo.site_id}" target="_blank">{$vo.site_id}</a></td>
                    <td><a href="?c=Plan&planid={$vo.plan_id}" target="_blank">{$vo.plan_id}</a></td>
                    <td><a href="?c=Ad&search_item_1=ad_id&search_item_val_1={$vo.ad_id}&ad_id={$vo.ad_id}" target="_blank">{$vo.ad_id}</a></td>
                    <td>{$vo.ip}{$vo.new_user|getNewUserCn}<br/>{:get_location_ip($vo['ip'])}</td>
                    <td>{$vo.resolution}</td>
                    <td>{$vo.opt_1|get_isp_type_cn}</td>
                    <td>{$vo.opt_2|get_net_type_cn}</td>
                    <td>{$vo.str_100_1}</td>
                    <td>{$vo.str_100_3}</td>
                    <td>{$vo.status|getDeductionStatusCn}</td>
                </tr>
                <tr>
                    <td colspan="13">
                        <ul class="clickDetailList">
                            <li><span>投放设备：</span>{:getDeviceName($vo['device'])}</li>
                            <li><span>浏览器：</span>{$vo.useragent}</li>
                            <li><span>运营商：</span>{$vo.opt_1|get_isp_type_cn}</li>
                            <li><span>联网方式：</span>{$vo.opt_2|get_net_type_cn}</li>
                            <li><span>手机系统：</span>{$vo.str_100_1}</li>
                            <li><span>系统版本：</span>{$vo.str_100_2}</li>
                            <li><span>手机品牌：</span>{$vo.str_100_3}</li>
                            <li><span>品牌明细：</span>{$vo.str_100_4}</li>
                        </ul>
                        <php>$click2Detail = getClick2Detail($_GET['day'], $vo['uid'], $vo['zone_id'], $vo['site_id'], $vo['ad_id'], $vo['ip']);</php>
                        <notempty name="click2Detail">
                        <fieldset class="click2Detail">
                            <legend>二次点击信息</legend>
                            <ul>
                                <li><span>进站时间：</span>{$click2Detail.in_time}</li>
                                <li><span>出站时间：</span>{$click2Detail.out_time}</li>
                                <li><span>停留时长：</span>{:timeSub($click2Detail['out_time'], $click2Detail['in_time'])}</li>
                                <li><span title="第一次点击与进站时间的间隔">第一次点击间隔：</span>{$click2Detail.first_click_time}</li>
                                <li><span>移动轨迹：</span>{$click2Detail.track}</li>
                                <li><span>链接点击数：</span>{$click2Detail.click_href_count}</li>
                                <li><span>任意位置点击数：</span>{$click2Detail.click_any_count}</li>
                            </ul>
                        </fieldset>
                        </notempty>
                    </td>
                </tr>
                </volist>
            </tbody>
        </table>
        
    </div><!--/#zoneBodyContent-->
</div><!--/#zoneBody-->
<div id="zoneFooter">{:W('Page/info', [$page])}</div><!--/#zoneFooter-->
<include file="Public:footer" />
